/**
 * @file hostfunc.c
 *
 * Copyright (c) Huawei Technologies Co., Ltd. 2023. All Rights reserved.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 */

#include "acl/acl_rt.h"
#include "runtime/kernel.h"

#if defined(__cplusplus)
extern "C" {
#endif

aclError aclrtSubscribeHostFunc(uint64_t hostFuncThreadId, aclrtStream exeStream) {
  return rtSubscribeHostFunc(hostFuncThreadId, (rtStream_t)exeStream);
}

aclError aclrtProcessHostFunc(int32_t timeout) {
  return rtProcessHostFunc(timeout);
}

aclError aclrtUnSubscribeHostFunc(uint64_t hostFuncThreadId, aclrtStream exeStream) {
  return rtUnSubscribeHostFunc(hostFuncThreadId, (rtStream_t)(exeStream));
}

#if defined(__cplusplus)
}
#endif